package top.infopub.mgr.bpa.domain;

import org.apache.commons.lang3.StringUtils;
import top.infopub.enums.bpa.ContTypeEnum;

import java.math.BigDecimal;

public class SubpackEntryDomain {

    /*pk*/
    private String id;
    /*项目编码*/
    private String proCode;
    /*项目名称*/
    private String proName;
    /*合同名称*/
    private String contractName;
    /*承包模式*/
    private String contType;
    /*总合同期(年)*/
    private BigDecimal contractYearTime;
    /*项目负责人*/
    private String projectLeader;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getProCode() {
        return proCode;
    }

    public void setProCode(String proCode) {
        this.proCode = proCode;
    }

    public String getProName() {
        return proName;
    }

    public void setProName(String proName) {
        this.proName = proName;
    }

    public String getContractName() {
        return contractName;
    }

    public void setContractName(String contractName) {
        this.contractName = contractName;
    }

    public String getContType() {
        return contType;
    }

    public void setContType(String contType) {
        this.contType = contType;
        if (StringUtils.isNotBlank(contType)) {
            ContTypeEnum ppdt = ContTypeEnum.getByCode(contType);
            if (ppdt != null) {
                setContType(ppdt.getName());
            }
        }
    }

    public BigDecimal getContractYearTime() {
        return contractYearTime;
    }

    public void setContractYearTime(BigDecimal contractYearTime) {
        this.contractYearTime = contractYearTime;
    }

    public String getProjectLeader() {
        return projectLeader;
    }

    public void setProjectLeader(String projectLeader) {
        this.projectLeader = projectLeader;
    }
}
